//
// Created by f on 2020/4/8.
//

#ifndef LANE_DETECTION_LANE_CLASS_H
#define LANE_DETECTION_LANE_CLASS_H

#include <deque>
#include "helper.h"

using std::deque;

class lane_class {
private:
    vector<cv::Point2i> left_pts;
    vector<cv::Point2i> right_pts;
    deque<vector<float>> cur_left_fit;
    deque<vector<float>> cur_right_fit;
public:
    lane_class();
    void init(const cv::Mat& img);
    void update(const cv::Mat& img);
    int max_saved_fit = 7;
    bool is_initialized;
    int bad_fit_count;
    vector<float> left_fit;
    vector<float> right_fit;
};


#endif //LANE_DETECTION_LANE_CLASS_H
